.q-tag {
  position: relative;
  box-sizing: border-box;
  display: inline-flex;
  align-items: center;
  max-width: 100%;
  padding-right: 8px;
  padding-left: 8px;
  margin-top: 2px;
  margin-right: 4px;
  margin-bottom: 2px;
  line-height: 20px;
  color: rgba(var(--color-rgb-gray), 0.64);
  background-color: var(--color-tertiary-gray-darker);
  border-radius: 2px;

  &_closable {
    padding-right: 2px;
  }

  &__text {
    display: -webkit-box;
    overflow: hidden;
    word-break: break-all;
    -webkit-line-clamp: 1;
    -webkit-box-orient: vertical;
  }

  &__close {
    width: 16px;
    height: 16px;
    padding: 0;
    margin-left: 4px;
    font-size: 16px;
    line-height: 1;
    color: rgba(var(--color-rgb-gray), 0.64);
    text-align: center;
    pointer-events: auto;
    cursor: pointer;
    background-color: transparent;
    border: none;

    &.focus-visible,
    &:hover {
      color: var(--color-primary-black);
      outline: none;
    }
  }
}
